<?php

class Core_Backend_Component_Promotion_View_Concessions_Import extends Core_Backend_Share_View_Form {

    protected function buildToolbar($toolbar) {
        $group = $toolbar->createGroup('back');
        $group->addLink($this->getHistoryUrl('promotion/concessions/index'), $this->__('share.button.back'));
        $group = $toolbar->createGroup('save');
        $group->addButton($this->__('share.button.save'))
                ->bindEvent('click', "Kdf.Ui.getForm('" . $this->getForm()->getId() . "').submit('" . $this->getUrl(NULL, 'import') . "')");
        parent::buildToolBar($toolbar);
    }

    protected function buildForm($form) {
        $form->setAttribute('enctype', 'multipart/form-data');
        $form->addFileField($this->__('share.label.select_file'), 'file', 'file');
        parent::buildForm($form);
    }

}